import random
n = int(input("Кол-во выстрелов: "))
z = 0
shoot = 0
while z < n:
    z = z + 1
    x = random.randint(-100, 100)
    y = random.randint(-100, 100)
    if x > 0 and x < 6 and y > 0 and y < 6:
       shoot = shoot + 1
    elif x > 0 and x < 6 and y < 0 and y > (-9):
        shoot = shoot + 1
    elif x < 0 and x > (-8) and y > 0 and y < 6:
        shoot = shoot + 1
    elif x < 0 and x > (-8) and y < 0 and y > (-9):
        shoot = shoot + 1
print("Кол-во попаданий: ", shoot)
